#include "Tree.h"
#include "../Managers/GameManager.h"
#include "../Managers/InputManager.h"
#include "../Maps/Forest.h"
#include "../GameObjects/Player.h"
#include "../Renderer/DeferredRenderer.h"

Tree::Tree(int radius)
	: GameObject(Vec2i(),147, TCODColor::darkerCrimson), radius(radius)
{
}

Tree::~Tree()
{
}

void Tree::init()
{
}

void Tree::update()
{
}

void Tree::render()
{
	auto g_buffer = GameManager::getSingleton()->getRenderer();
	g_buffer->addSymbol(pos, tile, 1.0f); //No symbol more important than the player
	Vec3f frgr_color(color.r / 255.0f, color.g / 255.0f, color.b / 255.0f);
	g_buffer->shade(pos, frgr_color, DeferredRenderer::RL_FOREGROUND, DeferredRenderer::RT_DIFFUSE);
	g_buffer->shade(pos, Vec3f(0.5f, 0.5f, 0.5f), DeferredRenderer::RL_FOREGROUND, DeferredRenderer::RT_SPECULAR);
	g_buffer->setMapInfo(pos, false, false);
}
